﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;

namespace QuanLyHocBongSinhVien
{
    public partial class Form1 : Form
    {
        public Form1()
        {
            InitializeComponent();
            BatTatMeNu(false);
        }

        public void BatTatMeNu(bool tthai)
        {
            mnuDanhMuc.Enabled = tthai;
            mnuChucNang.Enabled = tthai;
        }
        private void mnuSinhVien_Click(object sender, EventArgs e)
        {
            frmSinhVien frm = new frmSinhVien();
            frm.ShowDialog();
        }

        private void mnuKhoa_Click(object sender, EventArgs e)
        {
            frmKhoa frm = new frmKhoa();
            frm.ShowDialog();
        }

        private void mnuLoaiHocBong_Click(object sender, EventArgs e)
        {
            frmLoaiHocBong frm = new frmLoaiHocBong();
            frm.ShowDialog();
        }

        private void mnuMucHocBong_Click(object sender, EventArgs e)
        {
            frmMucHocBong frm = new frmMucHocBong();
            frm.ShowDialog();
        }

        private void mnuChiTietHB_Click(object sender, EventArgs e)
        {
            frmChiTietHocBongSinhVien frm = new frmChiTietHocBongSinhVien();
            frm.ShowDialog();
        }

        private void mnuNamHoc_Click(object sender, EventArgs e)
        {
            FrmNamHoc frm = new FrmNamHoc();
            frm.ShowDialog();
        }

        private void loaiHocBongNamHocToolStripMenuItem_Click(object sender, EventArgs e)
        {
            frmLoaiHocBong_NamHoc frm = new frmLoaiHocBong_NamHoc();
            frm.ShowDialog();
        }

        private void mnuDangNhap_Click(object sender, EventArgs e)
        {
            frmDangNhap frm = new frmDangNhap();
            frm.ShowDialog();
            mnuDangNhap.Enabled = true;
        }

        private void Form1_Load(object sender, EventArgs e)
        {

        }

        private void mnuDangXuat_Click(object sender, EventArgs e)
        {
            BatTatMeNu(false);
            mnuDangNhap.Enabled = true;
            mnuDangXuat.Enabled = false;
            mnuThoat.Enabled = true;
            MessageBox.Show("Ban da thoat khoi he thong");
        }

        private void mnuThoat_Click(object sender, EventArgs e)
        {
            Application.Exit();
        }

        private void mnuTimKiem_Click(object sender, EventArgs e)
        {
            FrmTimKiem frm = new FrmTimKiem();
            frm.ShowDialog();
        }

        private void mnuThongKe_Click(object sender, EventArgs e)
        {
            FrmThongKe frm = new FrmThongKe();
            frm.ShowDialog();
        }


       
    }
}
